package com.topc.code.judge;

import com.topc.code.judge.template.language.c.CNativeCodeSandbox;
import com.topc.code.judge.template.language.cpp.CppNativeCodeSandbox;
import com.topc.code.judge.template.language.java.JavaNativeCodeSandbox;
import com.topc.code.judge.template.language.python.PythonNativeCodeSandbox;

public class CodeSandboxFactory {

    public static CodeSandbox newInstance(String type){
           switch (type){
               case "cpp":
                   return new CppNativeCodeSandbox();
               case "java":
                   return new JavaNativeCodeSandbox();
               default:
                   return new CNativeCodeSandbox();
           }
    }
}
